package com.service.companyimpl;

import com.dao.CompanyMapper;
import com.model.Company;
import com.service.CompanyService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * 编写者：张佳齐
 * 编写时间：2019-5-29
 * 类模块描述：查询及相关增删改
 */
@Service
public class CompanyServiceImpl implements CompanyService {
    @Autowired
    private CompanyMapper companyMapper;
    @Override
    public Company selectByPrimaryKey(int cid){
        System.out.println("输入的参数为："+cid);
        return companyMapper.selectByPrimaryKey(cid);
    }

    @Override
    public List<Company> getAllC() {
        return companyMapper.getAllC();
    }

    @Override
    public int delC(Integer cid) {
        return companyMapper.delC(cid);
    }

    @Override
    public int insertC(Company companymodel) {
        return companyMapper.insertC(companymodel);
    }
}
